﻿
@{
    ViewBag.Title = "HiddenTroubleAdd";
    Layout = "~/Views/Shared/_LayoutMain.cshtml";
}
@section css {
    <style>
        .qrcode {
            float: right;
            position: absolute;
            top: 5px;
            right: 80px;
        }

        .center {
            position: fixed;
            top: 50%;
            left: 50%;
            background-color: #000;
            width: 600px;
            -webkit-transform: translateX(-50%) translateY(-50%);
            -moz-transform: translateX(-50%) translateY(-50%);
            -ms-transform: translateX(-50%) translateY(-50%);
            transform: translateX(-50%) translateY(-50%);
            border-radius: 3px;
        }
    </style>
}
<div class="page-content" ng-cloak ng-controller="HomeController" ng-init="SearchCheckForm={};SearchCheckForm.Year = '@DateTime.Now.Year';SearchCheckForm.Month = '@DateTime.Now.Month';SearchCheckForm.FormType='1';SearchH={};SearchH.Year='@DateTime.Now.Year';GetHiddenTroubleStateList();SearchH.State='';
     SearchEvent={};SearchEvent.Year = '@DateTime.Now.Year';
     LocationModel={};GetParkList();GetPlaceTree();InitPage();

     ">
    <div class="load" id="previewimg" ng-show="IsPreview" ng-click="ClosePreview();">
        <img id="imgshow" class="center" />
    </div>
    <div class="page-heading">
        <div id="qrcode" class="qrcode">

        </div>
        <h1>责任体系  &nbsp; &nbsp;{{LocationDetail.ParkInfo.ParkName}} {{LocationDetail.BuildingInfo.BuildingName}} {{LocationDetail.FloorInfo.FloorName}} {{LocationDetail.RoomName}}</h1>
        <div class="options">
            <div class="btn-toolbar">

            </div>
        </div>
    </div>
    <ol class="breadcrumb">
        <li><a>主页</a></li>
        <li class="active"><a>责任体系</a></li>
    </ol>

    <div class="container-fluid">
        <form class="form-horizontal row-border">
            <div class="row">

                <div class="col-md-12">
                    <div class="panel panel-default">
                        <div class="panel-heading"><h2>选择位置</h2></div>
                        <div class="panel-body">
                            <div class="form-group">
                                <label class="col-sm-1 control-label">园区：</label>
                                <div class="col-sm-2">
                                    <select class="form-control" ng-model="LocationModel.ParkId" ng-change="GetBuildingList(LocationModel.ParkId);">
                                        <option value="">请选择园区</option>
                                        <option ng-repeat="x in ParkList" value="{{x.Id}}">{{x.ParkName}}</option>
                                    </select>
                                </div>
                                <label class="col-sm-1 control-label">建筑物：</label>
                                <div class="col-sm-2">
                                    <select class="form-control" ng-model="LocationModel.BuildingId" ng-change="GetFloorList(LocationModel.BuildingId);">
                                        <option value="">请选择建筑物</option>
                                        <option ng-repeat="x in BuildingList" value="{{x.Id}}">{{x.BuildingName}}</option>
                                    </select>
                                </div>
                                <label class="col-sm-1 control-label">楼层：</label>
                                <div class="col-sm-2">
                                    <select class="form-control" ng-model="LocationModel.FloorId" ng-change="GetPlaceListByFloorId(LocationModel.FloorId);">
                                        <option value="">请选择楼层</option>
                                        <option ng-repeat="x in FloorList" value="{{x.Id}}">{{x.FloorName}}</option>
                                    </select>
                                </div>
                                <label class="col-sm-1 control-label">场所名称：</label>
                                <div class="col-sm-2">
                                    <select class="form-control" ng-model="LocationModel.RoomId" ng-change="ChangeRoom(LocationModel.RoomId);">
                                        <option value="">请选择场所</option>
                                        <option ng-repeat="x in RoomList" value="{{x.RoomId}}">{{x.PlaceName}}</option>
                                    </select>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
            <div class="row">

                <div class="col-md-12">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <h2>
                                <ul class="nav nav-tabs">
                                    <li class="dropdown pull-right tabdrop hide"><a class="dropdown-toggle" data-toggle="dropdown" href="#"><i class="fa fa-angle-down"></i> </a><ul class="dropdown-menu"></ul></li>
                                    <li class="active"><a href="#home" data-toggle="tab">场所责任</a></li>
                                    <li class=""><a href="#tab2" data-toggle="tab">场所责任人</a></li>
                                    <li class=""><a href="#tab2_1" data-toggle="tab">场所责任属性</a></li>
                                    <li class=""><a href="#tab3" data-toggle="tab">风险与措施</a></li>
                                    <li class=""><a href="#tab4" data-toggle="tab">设施设备</a></li>
                                    <li class=""><a href="#tab5" data-toggle="tab">检查台账</a></li>
                                    <li class=""><a href="#tab6" data-toggle="tab">问题整改</a></li>
                                    <li class=""><a href="#tab7" data-toggle="tab">事件</a></li>
                                    <li class=""><a href="#tab8" data-toggle="tab">监控</a></li>
                                </ul>
                            </h2>
                        </div>
                        <div class="panel-body">
                            <div class="tab-content">
                                <div class="tab-pane active" id="home">
                                    <table class="table table-striped table-bordered table-hover">
                                        <tr ng-repeat="y in ResponsibilityList track by $index">
                                            <td><span class="badge badge-info">{{$index+1}}</span></td>
                                            <td style="text-align:left;">{{y.ContentText}}</td>
                                        </tr>
                                    </table>
                                </div>
                                <div class="tab-pane" id="tab2">
                                    <table class="table table-striped table-bordered table-hover">
                                        <thead>
                                            <tr style="background-color:blueviolet;">
                                                <th style="width:5%;text-align:center;">序号</th>
                                                <th style="text-align:center;">级别名称</th>
                                                <th style="text-align:center;">检查频次</th>
                                                <th style="text-align:center;">负责人</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <tr ng-show="LevelList.length==0 && !DataLoading">
                                                <td colspan="7" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                            </tr>
                                            <tr ng-repeat="x in LevelList" ng-show="x.CheckInterval!='总部监督检查'">
                                                <td ng-bind="$index+1"></td>
                                                <td style="text-align:center;" ng-bind="x.LevelName"></td>
                                                <td style="text-align:center;" ng-bind="x.CheckInterval"></td>
                                                <td style="text-align:center;" ng-bind="x.UserCount"></td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </div>
                                <div class="tab-pane" id="tab2_1">
                                    <table class="table table-striped table-bordered table-hover">
                                        <thead>
                                            <tr style="background-color:blueviolet;">
                                                <th style="width:5%;">序号</th>
                                                <th style="width:5%;">责任属性</th>
                                                <th style="width:5%;">责任部门</th>
                                                <th style="width:5%;">责任人</th>
                                                <th style="width:5%;">备注</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <tr ng-repeat="x in AttrList">
                                                <td>{{$index+1}}</td>
                                                <td>{{x.ResponsibilityName}}</td>
                                                <td>{{x.DepartmentName}}</td>
                                                <td>{{x.UserList}}</td>
                                                <td>{{x.Remark}}</td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </div>
                                <div class="tab-pane" id="tab3">
                                    <table class="table table-striped table-bordered table-hover" ng-show="!PageLoading">
                                        <thead>
                                            <tr style="background-color:blueviolet;">
                                                <th style="width:5%;">序号</th>
                                                <th style="width:5%;">作业活动</th>
                                                <th style="width:5%;">固有风险等级</th>
                                                <th style="width:5%;">危险有害因素</th>
                                                <th style="width:10%;">后果</th>
                                                <th style="width:25%;">措施</th>
                                                <th style="width:5%;">风险评定等级</th>

                                                <th style="width:10%;">责任人</th>
                                            </tr>
                                        </thead>
                                        <tbody ng-show="RiskList.length==0 && !DataLoading">
                                            <tr>
                                                <td colspan="7" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                            </tr>
                                        </tbody>
                                        <tbody ng-repeat="x in RiskList track by $index" ng-show="RiskList.length>0">
                                            <tr ng-show="x.MeassuresList.length==0">
                                                <td>{{$index+1}}</td>
                                                <td>{{x.JobActivity}}</td>
                                                <td>{{x.LevelName}}</td>

                                                <td>{{x.RiskContent}}</td>
                                                <td>{{x.Consequence}}</td>
                                                <td>{{x.RatingName}}</td>
                                                <td></td>
                                                <td></td>
                                            </tr>
                                            <tr ng-show="x.MeassuresList.length>0" ng-repeat="i in x.MeassuresList track by $index">
                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{$parent.$parent.$index+1}}</td>
                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{x.JobActivity}}</td>
                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{x.LevelName}}</td>

                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{x.RiskContent}}</td>
                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{x.Consequence}}</td>
                                                <td>{{i.ContentText}}</td>
                                                <td ng-if="$index ==0" rowspan={{x.MeassuresList.length}}>{{x.RatingName}}</td>

                                                <td>{{i.UserList}}</td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </div>
                                <div class="tab-pane" id="tab4">
                                    <table class="table table-striped table-bordered table-hover" ng-show="!PageLoading">
                                        <thead>
                                            <tr>
                                                <th>序号</th>
                                                <th>设备类型</th>
                                                <th>设备名称</th>
                                                <th>规格型号</th>
                                                <th>管理部门</th>
                                                <th>状态</th>
                                                <th>日常管理频次</th>
                                                <th>维保单位</th>
                                                <th>维保频次</th>
                                                <th>备注</th>
                                            </tr>
                                        </thead>
                                        <tbody>
                                            <tr ng-show="DeviceList.length==0">
                                                <td colspan="12" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                            </tr>
                                            <tr ng-repeat="y in DeviceList">
                                                <td>
                                                    <span ng-bind="$index+1"></span>
                                                </td>
                                                <td>
                                                    <span>{{y.TypeName}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.DeviceName}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.ModelNo}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.DepartmentName}}</span>
                                                </td>

                                                <td><span class="badge badge-primary">{{y.Status | GetBoolStr}}</span></td>
                                                <td>
                                                    <span>{{y.ManageInterval}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.CompanyName}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.MaintenanceInterval}}</span>
                                                </td>
                                                <td>
                                                    <span>{{y.Remark}}</span>
                                                </td>
                                            </tr>
                                        </tbody>
                                    </table>
                                    <div class="text-center" ng-show="DeviceList!=null && DeviceList.length>0">
                                        <ul class="pagination  justify-content-center">
                                            <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetDeviceList(SearchModel,1);">首页</a></li>
                                            <li class="page-item" ng-class="{'active':result.currentPage==page}" ng-repeat="page in result.pages"><a style="cursor:pointer;" ng-click="GetDeviceList(SearchModel,page)" class="page-link" ng-bind="page"></a></li>
                                            <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetDeviceList(SearchModel,(result.currentPage + 1 > result.totalPage ? result.totalPage : result.currentPage + 1))">下一页</a></li>
                                            <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetDeviceList(SearchModel,result.totalPage);">尾页</a></li>
                                        </ul>
                                    </div>

                                </div>
                                <div class="tab-pane" id="tab5">
                                    <div class="row">
                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                年度：
                                                <select class="form-control" ng-model="SearchCheckForm.Year" ng-change="GetCheckFormPageList(SearchCheckForm);">
                                                    <option value="@(DateTime.Now.Year - 2)"> @(DateTime.Now.Year - 2)</option>
                                                    <option value="@(DateTime.Now.Year - 1)"> @(DateTime.Now.Year - 1)</option>
                                                    <option value="@DateTime.Now.Year" selected> @DateTime.Now.Year</option>
                                                </select>
                                            </label>
                                        </div>


                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                月份：
                                                <select class="form-control" ng-model="SearchCheckForm.Month" ng-change="GetCheckFormPageList(SearchCheckForm);">
                                                    @{
                                                        for (int i = 1; i <= 12; i++)
                                                        {
                                                            if (i == DateTime.Now.Month)
                                                            {
                                                                <option value="@i" selected>@i</option>
                                                            }
                                                            else
                                                            {
                                                                <option value="@i">@i</option>
                                                            }
                                                        }
                                                    }
                                                </select>
                                            </label>
                                        </div>


                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                类型：
                                                <select class="form-control" ng-model="SearchCheckForm.FormType" ng-change="GetCheckFormPageList(SearchCheckForm);">
                                                    <option>全部类型</option>
                                                    <option value="1" selected>日检</option>
                                                    <option value="2">周检</option>
                                                    <option value="3">月检</option>
                                                    <option value="4">季检</option>
                                                    <option value="5">半年检</option>
                                                    <option value="6">年检</option>
                                                </select>
                                            </label>
                                        </div>
                                        @*<div class="col-lg-1">
                                               <button type="button" class="btn btn-primary" ng-click="GetCheckFormPageList(SearchCheckForm);">查询</button>
                                            </div>*@

                                        @*<div class="col-lg-2">
                                                <label class="form-inline">
                                                    状态：
                                                    <select class="form-control">
                                                        <option>全部状态</option>
                                                        <option value="1" selected>异常</option>
                                                        <option>正常</option>
                                                    </select>
                                                </label>
                                            </div>*@
                                    </div>
                                    <div class="row" style="margin-top:20px;">
                                        <div class="col-lg-12">
                                            <div class="panel">
                                                <div class="panel-heading"><h2>台账数量：{{CheckFormPageList.length}}</h2></div>
                                                <div class="panel-body panel-no-padding">
                                                    <table class="table table-striped table-bordered table-hover" ng-show="!PageLoading">
                                                        <thead>
                                                            <tr>
                                                                <th>序号</th>
                                                                <th>场所</th>
                                                                <th>检查单号</th>
                                                                <th>检查日期</th>
                                                                <th>类型</th>
                                                                <th>部门</th>
                                                                <th>登记人</th>
                                                                <th>结果</th>
                                                                <th>操作</th>
                                                            </tr>
                                                        </thead>
                                                        <tbody>
                                                            <tr ng-show="CheckFormPageList.length==0 && !PageLoading">
                                                                <td colspan="12" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                                            </tr>
                                                            <tr ng-repeat="x in CheckFormPageList">
                                                                <td>
                                                                    <span ng-bind="$index+1"></span>
                                                                </td>
                                                                <td ng-bind="x.RoomName"></td>
                                                                <td ng-bind="x.FormNo"></td>

                                                                <td>{{x.CheckTime|JSONDate:'yyyy-MM-dd'}}</td>
                                                                <td>{{x.CheckTypeName}}</td>
                                                                <td ng-bind="x.DepartmentName"></td>
                                                                <td ng-bind="x.CreateUserName"></td>
                                                                <td><span ng-show="!x.IsException" class="badge badge-success">正常</span><span ng-show="x.IsException" class="badge badge-danger">异常</span></td>
                                                                <td><a data-toggle="modal" href="#detailModal" ng-click="GetCheckFormDetail(x.FormId);" class="btn btn-default btn-xs btn-label"><i class="fa fa-info"></i>详细</a></td>
                                                            </tr>
                                                        </tbody>
                                                    </table>
                                                </div>
                                            </div>

                                        </div>

                                    </div>

                                    @*<div class="text-center" ng-show="CheckFormPageList!=null && CheckFormPageList.length>0">
                                            <ul class="pagination  justify-content-center">
                                                <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetCheckFormPageList(SearchModel,1);">首页</a></li>
                                                <li class="page-item" ng-class="{'active':result.currentPage==page}" ng-repeat="page in result.pages"><a style="cursor:pointer;" ng-click="GetCheckFormPageList(SearchModel,page)" class="page-link" ng-bind="page"></a></li>
                                                <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetCheckFormPageList(SearchModel,(result.currentPage + 1 > result.totalPage ? result.totalPage : result.currentPage + 1))">下一页</a></li>
                                                <li class="page-item"><a class="page-link" style="cursor:pointer;" ng-click="GetCheckFormPageList(SearchModel,result.totalPage);">尾页</a></li>
                                            </ul>
                                        </div>*@
                                </div>
                                <div class="tab-pane" id="tab6">
                                    <div class="row">
                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                年度：
                                                <select class="form-control" ng-model="SearchH.Year" ng-change="GetHiddenTroubleList(SearchH);">
                                                    <option value="@(DateTime.Now.Year - 2)"> @(DateTime.Now.Year - 2)</option>
                                                    <option value="@(DateTime.Now.Year - 1)"> @(DateTime.Now.Year - 1)</option>
                                                    <option value="@DateTime.Now.Year" selected> @DateTime.Now.Year</option>
                                                </select>
                                            </label>
                                        </div>

                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                状态：
                                                <select class="form-control" ng-model="SearchH.State" ng-change="GetHiddenTroubleList(SearchH);">
                                                    <option value="">全部状态</option>
                                                    <option ng-repeat="x in HiddenTroubleStateList" value="{{x.Id}}">{{x.StateName}}</option>
                                                </select>
                                            </label>
                                        </div>

                                    </div>
                                    <div class="row">
                                        <div class="col-lg-12">
                                            <table class="table table-striped table-bordered table-hover">
                                                <thead>
                                                    <tr style="background-color:blueviolet;">
                                                        <th style="width:3%">序号</th>
                                                        <th style="width:3%">园区</th>
                                                        <th style="width:5%">来源</th>
                                                        <th style="width:5%">问题内容</th>
                                                        <th style="width:5%">问题等级</th>
                                                        <th style="width:8%">责任部门</th>
                                                        <th style="width:3%">责任人</th>
                                                        <th style="width:12%">地点/部位</th>
                                                        <th style="width:5%">检查时间</th>
                                                        <th style="width:5%">状态</th>
                                                        <th style="width:5%">响应到期时间</th>
                                                        <th style="width:5%">登记人</th>
                                                        <th style="width:5%">操作</th>
                                                    </tr>
                                                </thead>
                                                <tbody>
                                                    <tr ng-show="HiddenTroubleList.length==0">
                                                        <td colspan="13" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                                    </tr>
                                                    <tr id="tr_{{x.FormId}}" ng-repeat="x in HiddenTroubleList" ng-show="HiddenTroubleList.length>0">
                                                        <td ng-bind="$index+1"></td>
                                                        <td ng-bind="x.FactoryAreaName"></td>
                                                        <td ng-bind="x.SourceName"></td>
                                                        <td title="{{x.Description}}">{{x.Description|HideLongText}}</td>
                                                        <td ng-bind="x.LevelName"></td>
                                                        <td ng-bind="x.DepartmentName"></td>
                                                        <td ng-bind="x.EmployeeName"></td>
                                                        <td>{{x.PlaceName}}{{x.Location}}</td>
                                                        <td>{{x.CheckTime|JSONDate:'yyyy-MM-dd'}}</td>
                                                        <td ng-bind="x.StateName"></td>
                                                        <td>
                                                            <span ng-show="x.TimeProcess>=80 && x.StateName!='已完成'" class="label label-danger">{{x.InValidTime}}</span>
                                                            <span ng-show="x.TimeProcess>30 && x.TimeProcess<80 && x.StateName!='已完成'" class="label label-warning">{{x.InValidTime}}</span>
                                                            <span ng-show="x.TimeProcess<30 || x.StateName=='已完成'" class="label label-success">{{x.InValidTime}}</span>
                                                        </td>
                                                        <td ng-bind="x.CreateUserName"></td>
                                                        <td>
                                                            <a class="btn btn-default btn-xs btn-label"><i class="fa fa-info-circle"></i>详细</a>
                                                        </td>
                                                    </tr>
                                                </tbody>
                                            </table>

                                        </div>
                                    </div>
                                </div>
                                <div class="tab-pane" id="tab7">
                                    <div class="row">
                                        <div class="col-lg-2">
                                            <label class="form-inline">
                                                年度：
                                                <select class="form-control" ng-model="SearchEvent.Year" ng-change="GetEventReportList(SearchEvent);">
                                                    <option value="@(DateTime.Now.Year - 2)"> @(DateTime.Now.Year - 2)</option>
                                                    <option value="@(DateTime.Now.Year - 1)"> @(DateTime.Now.Year - 1)</option>
                                                    <option value="@DateTime.Now.Year" selected> @DateTime.Now.Year</option>
                                                </select>
                                            </label>
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-lg-12">
                                            <table class="table table-striped table-bordered table-hover">
                                                <thead>
                                                    <tr>
                                                        <th>序号</th>
                                                        <th>事件编号</th>
                                                        <th>所在园区</th>
                                                        <th>所在场所</th>
                                                        <th>责任部门</th>
                                                        <th>报告时间</th>
                                                        <th>问题描述</th>
                                                        <th>操作</th>
                                                    </tr>
                                                </thead>
                                                <tbody>
                                                    <tr ng-show="EventReportList.length==0">
                                                        <td colspan="12" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                                    </tr>
                                                    <tr ng-repeat="x in EventReportList">
                                                        <td>
                                                            <span ng-bind="$index+1"></span>
                                                        </td>
                                                        <td ng-bind="x.EventNo"></td>
                                                        <td>{{x.ParkName}}</td>
                                                        <td>{{x.PlaceName}}</td>
                                                        <td ng-bind="x.DepartmentName"></td>


                                                        <td>{{x.ReportTime|JSONDate:'yyyy-MM-dd HH:mm'}}</td>
                                                        <td ng-bind="x.EventContent"></td>
                                                        <td>
                                                            <a data-toggle="modal" href="#EventDetailModal" ng-click="GetEventReportDetail(x.Id);" class="btn btn-default btn-xs btn-label"><i class="fa fa-info-circle"></i>详细</a>
                                                        </td>
                                                    </tr>
                                                </tbody>
                                            </table>
                                        </div>
                                    </div>
                                </div>
                                <div class="tab-pane" id="tab8">
                                    建设中......
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>


        </form>
    </div>
    <div class="demo-options">
        <div class="demo-options-icon"><i class="fa fa-fw fa-building-o"></i></div>
        <div class="demo-heading">场所分布</div>

        <div class="demo-body">
            <div class="tabular">
                <div id="tree-default">
                    <ul>
                        <li data-jstree='{ "icon" : "fa fa-home text-success" }' ng-repeat="x in ParkTreeList">
                            {{x.ParkName}}
                            <ul ng-show="x.BuildingList>0">
                                <li ng-repeat="y in x.BuildingList" data-jstree='{ "icon" : "fa fa-building text-primary" }'>
                                    {{y.BuildingName}}
                                    <ul ng-show="y.FloorList>0">
                                        <li data-jstree='{ "icon" : "fa fa-bookmark" }' ng-repeat="z in y.FloorList">
                                            {{z.FloorName}}
                                            <ul ng-show="z.RoomList>0">
                                                <li data="{{r.Id}}" id="LINK_{{r.Id}}" data-jstree='{ "type" : "file" }' ng-repeat="r in z.RoomList">
                                                    <a>{{r.RoomName}}</a>
                                                </li>
                                            </ul>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>

    <div class="modal fade" id="detailModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <form class="form-horizontal row-border">
            <div class="modal-dialog" style="min-width:1300px;">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                        <h2 class="modal-title">检查详情</h2>
                    </div>
                    <div class="modal-body">
                        <div class="form-group">
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>部门：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.DepartmentName" readonly />
                            </div>
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>部位名称：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.RoomName" readonly />
                            </div>
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>部门负责人：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.Manager" readonly />
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>责任人：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.ResponsibleName" readonly />
                            </div>
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>检查日期：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.CheckTime" readonly />
                            </div>
                            <label class="col-sm-1 control-label"><b style="color:red;"></b>检查类型：</label>
                            <div class="col-sm-3">
                                <input type="text" class="form-control" ng-model="CheckDetail.CheckTypeName" readonly />
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-sm-12">
                                <table class="table table-striped table-bordered table-hover" ng-show="!PageLoading">
                                    <thead>
                                        <tr>
                                            <th style="width:5%;">序号</th>
                                            <th style="width:35%;">检查内容</th>
                                            <th style="width:10%;">检查结果</th>
                                            <th style="width:5%;">测量值</th>
                                            <th style="width:25%;">照片</th>
                                            <th style="width:15%;">备注</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                        <tr ng-repeat="x in CheckDetail.CheckItemList">
                                            <td>{{$index+1}}</td>
                                            <td style="text-align:left;">{{x.CheckContent}}</td>
                                            <td>
                                                <span ng-show="x.Result==1" class="label label-info">正常</span>
                                                <span ng-show="x.Result==0" class="label label-danger">异常</span>
                                            </td>
                                            <td>
                                                <input type="text" ng-model="x.DataValue" readonly class="form-control" ng-show="x.IsValue" />
                                                <b ng-show="!x.IsValue">一</b>
                                            </td>
                                            <td>
                                                <div ng-repeat="y in x.FileList" style="float:left;width:50px;margin-left:10px;">
                                                    <img ng-src="{{y.FilePath}}" width="40" height="40" />
                                                    <a ng-click="ShowPicture(y.FilePath);" class="btn btn-primary btn-xs btn-label"><i class="fa fa-arrows-alt"></i>预览</a>
                                                </div>
                                            </td>
                                            <td><input type="text" class="form-control" readonly ng-model=" x.Remark" /></td>
                                        </tr>
                                    </tbody>
                                </table>
                            </div>

                        </div>
                        <div class="form-group" ng-show="CheckDetail.IsException && CheckDetail.StateName!=''">
                            <label class="col-sm-2 control-label" style="text-align:left;"><b style="color:red;"></b>问题状态：<b>{{CheckDetail.StateName}}</b>, <a target="_blank" href="../../HiddenTrouble/HiddenTroubleDetail?FormId={{CheckDetail.IssueId}}">详情</a></label>

                        </div>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                    </div>
                </div>
            </div><!-- /.modal-dialog -->
        </form>
    </div><!-- /.modal -->
    <div class="modal fade" id="EventDetailModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <form class="form-horizontal row-border">
            <div class="modal-dialog" style="min-width:1300px;">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                        <h2 class="modal-title">事件详情</h2>
                    </div>
                    <div class="modal-body">
                        <div class="form-group">
                            <label class="col-sm-1 control-label">园区：</label>
                            <div class="col-sm-8">
                                <input type="text" class="form-control" ng-model="EventReportDetail.ParkName" disabled />
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="col-sm-1 control-label">场所：</label>
                            <div class="col-sm-8">
                                <input type="text" class="form-control" ng-model="EventReportDetail.PlaceName" disabled />
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">报告时间：</label>
                            <div class="col-sm-8">
                                <input type="text" class="form-control" ng-model="EventReportDetail.ReportTime" disabled />
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">报告层级：</label>
                            <div class="col-sm-8">
                                <div class="checkbox-inline"><label><input type="checkbox" checked disabled>上级管理者</label></div>
                                <div class="checkbox-inline"><label><input type="checkbox" ng-checked="EventReportDetail.ReportLevel==2" id="level2">安委办</label></div>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">事件描述：</label>
                            <div class="col-sm-8">
                                <textarea type="text" ng-model="EventReportDetail.EventContent" placeholder="事件描述" rows="8" class="form-control" disabled></textarea>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">处理情况：</label>
                            <div class="col-sm-8">
                                <textarea type="text" ng-model="EventReportDetail.DealContent" ng-init="EventReportDetail.DealContent=''" placeholder="处理情况" rows="8" class="form-control"></textarea>
                            </div>
                            <label class="control-label">{{EventReportDetail.DealContent.length}}/500</label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">验证人：</label>
                            <div class="col-sm-8">
                                <input id="startTime" class="form-control" ng-model="EventReportDetail.CheckUser" />
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">验证时间：</label>
                            <div class="col-sm-8">
                                <input type="text" class="form-control" ng-model="EventReportDetail.CheckTime" disabled />
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-1 control-label">文件列表：</label>
                            <div class="col-sm-8">
                                <table class="table table-striped table-bordered table-hover">
                                    <thead>
                                        <tr style="background-color:blueviolet;">
                                            <th style="width:5%">序号</th>
                                            <th style="width:30%">文件名称</th>
                                            <th style="width:10%">文件大小(kb)</th>
                                            <th style="width:10%">操作</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                        <tr ng-show="EventReportDetail.FileList.length==0">
                                            <td colspan="4" style="text-align:center;vertical-align:middle;line-height:30px;">没有数据</td>
                                        </tr>
                                        <tr ng-repeat="x in EventReportDetail.FileList">
                                            <td ng-bind="$index+1"></td>
                                            <td ng-bind="x.FileName"></td>
                                            <td ng-bind="x.FileSize"></td>
                                            <td>
                                                <a href="../Download/DownloadFile?FileId={{x.FileId}}" class="btn btn-success btn-xs btn-label"><i class="fa fa-download"></i>下载</a>
                                            </td>
                                        </tr>
                                    </tbody>
                                </table>
                            </div>
                        </div>
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                    </div>
                </div>
            </div><!-- /.modal-dialog -->
        </form>
    </div><!-- /.modal -->
    <div class="modal fade" id="EventDetailModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <form class="form-horizontal row-border">
            <div class="modal-dialog" style="min-width:1300px;">
                <div class="modal-content">
                    <div class="modal-header">
                        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                        <h2 class="modal-title">问题详情</h2>
                    </div>
                    <div class="modal-body">
                        
                    </div>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                    </div>
                </div>
            </div><!-- /.modal-dialog -->
        </form>
    </div><!-- /.modal -->
</div>
@section Js{
    <script src="~/Assets/js/libs/qrcode.js"></script>
    <script src="~/Assets/plugins/jstree/dist/jstree.min.js"></script>
    <script src="~/Assets/js/pg/Home.js?v=@DateTime.Now.ToString("yyMMddHHmm")"></script>

    <script>
        $(".demo-options-icon").click(function () {
            $('.demo-options').toggleClass("active");
        });

        setTimeout(function () {

        }, 3000);
    </script>
}

